package com.taotao.web.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import com.taotao.web.service.IndexService;

@Controller
@RequestMapping("index")
public class IndexController {
	
	@Autowired
	private IndexService indexService;

	@GetMapping
	public String toIndex(Model model){
		
		String bigADs = this.indexService.queryBigADs();
		model.addAttribute("bigADs", bigADs);
		
		return "index";
	}
}
